package org.csmzxy.class2333;

abstract class Department {
    String name;
    int numOfMembers;
    public abstract void work();
}
class TechDepartment extends Department{
    public TechDepartment(String name,int numOfMembers){
        super.name = name;
        super.numOfMembers = numOfMembers;
    }
    @Override
    public void work(){
        System.out.println(super.name + "负责技术研发、软件开发和系统维护等，" + "部门有" + super.numOfMembers + "人。");
    }
}
class SaleDepartment extends Department{
    public SaleDepartment(String name,int numOfMembers){
        super.name = name;
        super.numOfMembers = numOfMembers;
    }
    @Override
    public void work(){
        System.out.println(super.name + "负责销售业务拓展、市场营销策划等，" + "部门有" + super.numOfMembers + "人。");
    }
}
